﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Admin/ContentFrame.master" AutoEventWireup="true" CodeBehind="BatchGenerateFacility.aspx.cs"
    Inherits="ETD.WebManagement.Admin.FacilityManage.BatchGenerateFacility" %>

<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">

    <div class="edit_form_container width800" runat="server" id="searchPanel">
        <div class="form_filed_container width800">
            <label class="form_filed_label">设备批次：</label>
            <telerik:RadTextBox ID="txtBatch" MaxLength="8" Width="600px" runat="server" Enabled="false"></telerik:RadTextBox>
        </div>

         <div class="form_filed_container width800">
            <label class="form_filed_label">分组：</label>
            <telerik:RadComboBox ID="ddlFacilityGroup" runat="server" Width="600px">
            </telerik:RadComboBox>
        </div>

        <div class="form_filed_container width800">
            <label class="form_filed_label">数量：</label>
            <telerik:RadNumericTextBox ID="txtCount" runat="server" Width="600px" Type="Number"
                NumberFormat-DecimalDigits="0" MinValue="0" MaxValue="100000000">
            </telerik:RadNumericTextBox>

        </div>

        <div class="form_action_button width500">
            <telerik:RadButton CssClass="hidden" ID="btnOk" runat="server" Text="确定" OnClick="btnOk_Click" Width="120px">
            </telerik:RadButton>
             <telerik:RadButton ID="btnOkClient" runat="server" Text="确定" AutoPostBack="false" Width="120px" OnClientClicked="onBtnGenerateClick">
            </telerik:RadButton>
            &nbsp; &nbsp;           
                            <telerik:RadButton ID="btnCancel" runat="server" Text="取消" Width="120px"
                                AutoPostBack="false"
                                OnClientClicked="onBtnCancelClick">
                            </telerik:RadButton>
        </div>
    </div>

    <telerik:RadCodeBlock ID="RadCodeBlock1" runat="server">
        <script type="text/javascript">
            var FacilitysPageUrl = '<%=ResolveClientUrl("/Admin/FacilityManage/Facilitys.aspx") %>';
            var btnOkClientID = '<%=btnOk.ClientID %>';
            function onBtnCancelClick() {
                onCancelButtonConfirm(redirectToFacilitysPage);
            }
            function redirectToFacilitysPage(isConfirm) {
                RedirectPage(FacilitysPageUrl);
            }
            function saveBatchGenerateFacilityCallback() {
                RedirectPage(FacilitysPageUrl);
            }
            function onBtnGenerateClick() {
                if (confirm("确认，要生成吗？")) {
                    if (confirm("二次确认，要生成吗？")) {
                        var loading = layer.load();
                        $("#" + btnOkClientID).click();
                        return true;
                    }
                }
                return false;
            }
        </script>
    </telerik:RadCodeBlock>
</asp:Content>

